﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Web;
using MAF.Common;
using Domain.Entities;
using Domain;
using Business;
using MAF.CRUD;

namespace Web.Controller
{
    public class MessageHandler : BaseHandler<MessageInfo>
    {
        private string _module = null;

        public MessageHandler()
        {
            _module = HttpContext.Current.Request["Module"];
        }

        public MessageHandler(string module)
        {
            _module = module;
        }

        protected override ICRUD<MessageInfo> GetService()
        {
            return BusinessFactory.CreateMessage(_module);
        }
    }
}